﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Web.Http;
using Deixei.Domain;

namespace Deixei.Web.Controllers
{
    public abstract class DeixeiApiController : ApiController
    {
        public IUnitOfWork UnitOfWork
        {
            get;
            set;
        }

        public DeixeiApiController()
        {
            UnitOfWork = new UnitOfWork();
        }

        protected override void Dispose(bool disposing)
        {
            UnitOfWork.Dispose();
            base.Dispose(disposing);
        }
    }
}
